<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>Luminance HDR User Manual — DCRaw reference</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<link href="style.css" rel="stylesheet" type="text/css" />
</head>
<body>

<h2>DCRaw reference</h2>

<p>Here's an excerpt from <a href="http://cybercom.net/~dcoffin/dcraw/dcraw.1.html">DCRaw's man page</a> (Retrieved: October 30, 2007).</p>

<dl>
<dt><b>-v</b></dt>
<dd>Print verbose messages, not just warnings and errors.</dd>
<dt><b>-c</b></dt>
<dd>Write decoded images or thumbnails to standard output.</dd>
<dt><b>-e</b></dt>
<dd>Extract the camera-generated thumbnail, not the raw image. You'll get either a JPEG or a PPM file, depending on the camera. 
<dt><b>-z</b></dt>
<dd>Change the access and modification times of an AVI, JPEG, TIFF or raw file to when the photo was taken, assuming that the camera clock was set to Universal Time. 
<dt><b>-i</b></dt>
<dd>Identify files but don't decode them. Exit status is 0 if dcraw can decode the last file, 1 if it can't. -i -v shows metadata. dcraw cannot decode JPEG files!! 
<dt><b>-d</b></dt>
<dd>Show the raw data as a grayscale image with no interpolation. Good for photographing black-and-white documents. 
<dt><b>-D</b></dt>
<dd>Same as -d, but totally raw (no color scaling). 
<dt><b>-h</b></dt>
<dd>Output a half-size color image. Twice as fast as -q 0. 
<dt><b>-q 0</b></dt>
<dd>Use high-speed, low-quality bilinear interpolation. 
<dt><b>-q 1</b></dt>
<dd>Use Variable Number of Gradients (VNG) interpolation. 
<dt><b>-q 2</b></dt>
<dd>Use Patterned Pixel Grouping (PPG) interpolation. 
<dt><b>-q 3</b></dt>
<dd>Use Adaptive Homogeneity-Directed (AHD) interpolation. 
<dt><b>-f</b></dt>
<dd>Interpolate RGB as four colors. Use this if the output shows false 2x2 meshes with VNG or mazes with AHD. 
<dt><b>-m number_of_passes</b></dt>
<dd>After interpolation, clean up color artifacts by repeatedly applying a 3x3 median filter to the R-G and B-G channels. 
<dt><b>-n noise_threshold</b></dt>
<dd>Use wavelets to erase noise while preserving real detail. The best threshold should be somewhere between 100 and 1000. 
<dt><b>-b brightness</b></dt>
<dd>By default, dcraw writes 8-bit PGM/PPM/PAM with a BT.709 gamma curve and a 99th-percentile white point. If the result is too light or too dark, -b lets you adjust it. Default is 1.0. 
<dt><b>-4</b></dt>
<dd>Write 16-bit linear pseudo-PGM/PPM/PAM with no gamma curve, no white point, and no -b option. 
<dt><b>-T</b></dt>
<dd>Write TIFF output (with metadata) instead of PGM/PPM/PAM. 
<dt><b>-k black</b></dt>
<dd>Set the black point. Default depends on the camera. 
<dt><b>-K darkframe.pgm</b></dt>
<dd>Subtract a dark frame from the raw data. To generate a dark frame, shoot a raw photo with no light and do dcraw -D -4 -j -t 0. 
<dt><b>-w</b></dt>
<dd>Use the white balance specified by the camera. If this is not found, print a warning and use another method. 
<dt><b>-a</b></dt>
<dd>Calculate the white balance by averaging the entire image. 
<dt><b>-A left top width height</b></dt>
<dd>Calculate the white balance by averaging a rectangular area. First do dcraw -j -t 0 and select an area of neutral grey color. 
<dt><b>-r mul0 mul1 mul2 mul3</b></dt>
<dd>Specify your own raw white balance. These multipliers can be cut and pasted from the output of dcraw -v. 
<dt><b>no white balance option</b></dt>
<dd>Use a fixed white balance based on a color chart illuminated with a standard D65 lamp.</dd>
<dt><b>+M or -M</b></dt>
<dd>Use (or don't use) any color matrix from the camera metadata. The default is +M if -w is set, -M otherwise. This option only affects Olympus, Leaf, and Phase One cameras. 
<dt><b>-C red_mag blue_mag</b></dt>
<dd>Enlarge the raw red and blue layers by the given factors, typically 0.999 to 1.001, to correct chromatic aberration. 
<dt><b>-H 0</b></dt>
<dd>Clip all highlights to solid white (default). 
<dt><b>-H 1</b></dt>
<dd>Leave highlights unclipped in various shades of pink. 
<dt><b>-H 2</b></dt>
<dd>Blend clipped and unclipped values together for a gradual fade to white. 
<dt><b>-H 3-9</b></dt>
<dd>Reconstruct highlights. Low numbers favor whites; high numbers favor colors. Try -H 5 as a compromise. If that's not good enough, do -H 9, cut out the non-white highlights, and paste them into an image generated with -H 3. 
<dt><b>-o [0-5]</b></dt>
<dd>Select the output colorspace when the -p option is not used:
<pre>    0   Raw color (unique to each camera)
    1   sRGB D65 (default)
    2   Adobe RGB (1998) D65
    3   Wide Gamut RGB D65
    4   Kodak ProPhoto RGB D65
    5   XYZ </pre></dd>
<dt><b>-p camera.icm [ -o output.icm ]</b></dt>
<dd>Use ICC profiles to define the camera's raw colorspace and the desired output colorspace (sRGB by default).</dd>
<dt><b>-p embed</b></dt>
<dd>Use the ICC profile embedded in the raw photo. </dd>
<dt><b>-t [0-7,90,180,270]</b></dt>
<dd>Flip the output image. By default, dcraw applies the flip specified by the camera. -t 0 disables all flipping. </dd>
<dt><b>-s [0..N-1] or -s all</b></dt>
<dd>If a file contains N raw images, choose one or "all" to decode. For example, Fuji Super CCD SR cameras generate a second image underexposed four stops to show detail in the highlights. </dd>
<dt><b>-j</b></dt>
<dd>For Fuji Super CCD cameras, show the image tilted 45 degrees. For cameras with non-square pixels, do not stretch the image to its correct aspect ratio. In any case, this option guarantees that each output pixel corresponds to one raw pixel. </dd>
<dl>

</body>
</html>
